home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1995 October / EnigmA AMIGA RUN 01 (1995)(G.R. Edizioni)(IT)[!][issue 1995-10][Aminet 7].iso / Aminet / demo / sound / tp_austr.lha / Australia.Install next >
Text File  |  1992-02-26  |  11KB  |  370 lines

  1. ; The Problem's Australia EP Installer Script.
  2. ; Written with help of ASCII-Edit in March/May 1995.
  3.  
  4. ;two vars for scrolling logo through window
  5. SET scrollUP HBBBBBBBBBBBBBBBBBB
  6. SET scrollDN HAAAAAAAAAAAAAAAAAAA
  7. SET empty "C >                                                                       "
  8.  
  9. SETFONT topaz.font 8
  10.  
  11. IF NOT Exists Australia-Install
  12.   ECHO "You  have  either already installed Australia, or something weird happened!*nI can not find this directory:*n`CD`Australia-Install/"
  13.   ECHO NOLINE "*n*n > Press Return "
  14.   SET >NIL: Return ?
  15.   ENDCLI
  16. ENDIF
  17.  
  18. ;Install the cli-commands first
  19. CD Australia-install/cli-stuff
  20. ECHO NOLINE "Please wait...*n*nInstalling missing commands in C: ..."
  21. ;COPY >NIL: Cli-Stuff/#? C:
  22. LIST >RAM:comms LFORMAT "IF NOT EXISTS c:%m *n copy %s C:*nENDIF"
  23. EXECUTE >NIL: RAM:comms
  24. DELETE >NIL: RAM:comms
  25. COPY AmigaGuide C:
  26. CD /
  27. COPY >NIL: ASCIIEdit.config S:
  28. DELETE >NIL: Cli-Stuff ALL
  29. DELETE >NIL: ASCIIEdit.config 
  30. SetRGB >NIL: RESET
  31. ;
  32. ;The following part magically converts the "Install.DATA" file to a
  33. ;protracker module, loads it into SmartPlay and then deletes it...
  34. IF EXISTS Install.DATA
  35.   ECHO NOLINE "...done!*nLoading & Converting Install.DATA file ..."
  36.   ECHO NOLINE >RAM:Header piano
  37.   JOIN RAM:Header Install.DATA TO RAM:Mod.Piano
  38.   DELETE >NIL: RAM:Header
  39.   SP RAM:Mod.Piano NW NM NE NC
  40.   DELETE >NIL: RAM:Mod.Piano
  41.   ECHO "...done!"
  42. ENDIF
  43.  
  44. ECHO "*ec"
  45. TYPE TP-Logo.ASCII
  46. WAIT 1
  47.  
  48. TYPE TP-AUSTRALIA.ASCII
  49. WAIT 1
  50.  
  51. ECHO HCPress ReturnC(C)1995 by The ProblemH
  52. SET >NIL: Return ?
  53.  
  54. ECHO "*ec"
  55. TYPE TP-AUSTRALIA.ASCII
  56. WAIT 1
  57.  
  58. ;scroll up half a screen and display info
  59. ECHO BBBBBBBBBBBBBBBBBH
  60. ECHO "HCWelcome to The Problem's Australia EP installer.*n"
  61. ECHO " This  script will fully install the Australia EP where you want it.  Please*n note  that  you  need  about 5 Mb of free space on your harddisk during the*n installation.  After installation, Australia will take up about 2.6Mb.*n"
  62. ECHO " It IS VITAL that you use this installer.  If you copy stuff by hand, we can*n ensure  you  that  some things in the EP won't work.  (Some files have been*n deliberately corrupted; they will be restored by the installer.)*n"
  63. ECHO " Coming  up  is  a  Path  Requester in which you should choose a destination*n directory.   If you are unsure wether you have enough diskspace, cancel the*n requester to quit the installation procedure."
  64. ECHO NOLINE "HC Press Return "
  65. SET >NIL: Return ?
  66. ECHO "HC              "
  67.  
  68. ;where to install, the Path requester...
  69. LAB Repeat
  70. SET Path ""
  71. SET Path `RequestFile DRAWER "Ram:" DRAWERSONLY TITLE "Select Path for AUSTRALIA!" POSITIVE "Install Here" NEGATIVE "Quit!"`
  72.  
  73. IF NOT $Path
  74.   ECHO "H  Are you sure you DON'T want to install Australia? (Y/N)"
  75.   SET YPos H
  76.   SET YES "Yeah! I hate installing EP's! (What?!) "
  77.   SET NO "No! O my God! What have I done!?! (you pressed Quit!...) "
  78.   SET label Quit
  79.   SKIP SUB_YesNo
  80. ELSE
  81.   SKIP DontQuit
  82. ENDIF
  83.  
  84. LAB Quit
  85. IF $answer EQ Y
  86.   SP STOP
  87.   ENDCLI
  88. ELSE
  89.   SKIP BACK Repeat
  90. ENDIF
  91.  
  92. LAB DontQuit
  93. DELETE >NIL: Install.DATA
  94. ECHO $scrollDN
  95.  
  96. LAB questions
  97. ECHO "H Okay, now please answer the following questions...*n"
  98.  
  99. ECHO " Do you want 8-colour Magic WB icons (in stead of 4-colour)? (Y/N)"
  100. ECHO "H$emptyHC"
  101. ECHO "*n Do you want the new WB backdrop to be activated? (in prefs file!) (Y/N)"
  102. ECHO "H$emptyHC"
  103. ECHO "*n Do you run an 'interlaced' workbench? (Y/N)"
  104. ECHO "H$emptyHC"
  105. ECHO "*n Are you sure about all this? (Y/N)"
  106. ECHO "H$emptyHC"
  107. ECHO ""
  108.  
  109. ;the following makes use of the 'sub-routine', (see further down)
  110. LAB Repeat2
  111.   SET Ypos H
  112.   SET YES "Yes please, give me the beautyfull ones!"
  113.   SET NO "No, I want 4 colour icons..."
  114.   SET label Repeat3
  115.   SKIP SUB_YesNo
  116.  
  117. LAB Repeat3
  118.   SET Q1 $answer
  119.   SET Ypos H
  120.   SET YES "Yes, I guess I do."
  121.   SET NO "No, just leave me alone will you!"
  122.   SET label Repeat4
  123.   SKIP SUB_YesNo
  124.  
  125. LAB Repeat4
  126.   SET Q2 $answer
  127.   SET Ypos H
  128.   SET YES "Yes, I've got loads of memory and/or own a multiscan monitor!"
  129.   SET NO "No, I'm just an honest bloke! (Or I own a 1 GIG HD instead!)"
  130.   SET label Repeat5
  131.   SKIP SUB_YesNo
  132.  
  133. LAB Repeat5
  134.   SET Q3 $answer
  135.   SET Ypos H
  136.   SET YES "Yes, I'm not stupid you know!"
  137.   SET NO "No, I made a little mistake."
  138.   SET label Continue
  139.   SKIP SUB_YesNo
  140.  
  141. LAB Continue
  142.   SET Q4 $answer
  143.   ECHO NOLINE "*n*n*nC Hit The Return Key! (Again) "
  144.   SET >NIL: Return ?
  145.  
  146.   IF $Q4 EQ N
  147.     ECHO "AC          Try again!         "
  148.     SKIP BACK questions 
  149.   ENDIF
  150.  
  151.   ECHO $scrollUP$scrollUP
  152.  
  153.  
  154. ;And now for the backdrops...
  155. ECHO "*ec"
  156. ECHO "You  will  now have the opportunity to select which background picture will*nbe  installed.   Wether or not you have chosen to activate it, we will copy*nit  to  your  SYS:Prefs/Patterns  directory."
  157.  
  158. SET label BACKSELEC1
  159. IF $Q1 EQ Y
  160.   SKIP Pics8col
  161. ELSE
  162.   SKIP Pics4col
  163. ENDIF
  164.  
  165. LAB BACKSELEC1
  166. ECHO "*n*n*nC  1  C  2  "
  167. IF $Q3 EQ Y
  168.   ECHO "H        These are nonlaced versions. A laced version will be installed!    "
  169. ENDIF
  170.  
  171. LAB BACKSELEC2
  172. ECHO NOLINE "HEnter your choice:                  D"
  173. SET >NIL: back ?
  174.  
  175. CD Backdrops/
  176. SET patterns "SYS:Prefs/Patterns/AustBugles"
  177. IF NOT EXISTS SYS:Prefs/Patterns/"
  178.   MakeDir >NIL: SYS:Prefs/Patterns
  179. ENDIF
  180. IF NOT VAL "$back" EQ 1
  181.   IF NOT VAL "$back" EQ 2
  182.     SKIP BACK BACKSELEC2
  183.   ELSE
  184.     IF $Q1 EQ Y
  185.       IF $Q3 EQ Y
  186.         COPY >NIL: Bugles2.HL $patterns
  187.       ELSE
  188.         COPY >NIL: Bugles2 $patterns
  189.       ENDIF
  190.     ELSE
  191.       IF $Q3 EQ Y
  192.         COPY >NIL: Bugles4.HL $patterns
  193.       ELSE
  194.         COPY >NIL: Bugles4 $patterns
  195.       ENDIF
  196.     ENDIF
  197.   ENDIF
  198. ELSE
  199.   IF $Q1 EQ Y
  200.     IF $Q3 EQ Y
  201.       COPY >NIL: Bugles1.HL $patterns
  202.     ELSE
  203.       COPY >NIL: Bugles1 $patterns
  204.     ENDIF
  205.   ELSE
  206.     IF $Q3 EQ Y
  207.       COPY >NIL: Bugles3.HL $patterns
  208.     ELSE
  209.       COPY >NIL: Bugles3 $patterns
  210.     ENDIF
  211.   ENDIF
  212. ENDIF
  213.  
  214. ;Copy window backdrop
  215. COPY >NIL: AustraliaWindows sys:prefs/patterns/
  216.  
  217. CD /
  218. DELETE >NIL: Backdrops ALL
  219. ECHO "*ec"
  220. TYPE TP-AUSTRALIA.ASCII
  221. ECHO "HThe selected pattern has been installed."
  222. IF $Q2 EQ Y
  223.   IF $Q1 EQ Y
  224.     COPY >NIL: WbPattern8.prefs SYS:Prefs/Env-Archive/Sys/WbPattern.prefs
  225.     ECHO "HAn 8 colour Window Backdrop has been copied to your SYS:Prefs/Patterns*ndirectory. This backdrop has also been actived in WBPattern.prefs!"
  226.   ELSE
  227.     COPY >NIL: WbPattern4.prefs SYS:Prefs/Env-Archive/Sys/WbPattern.prefs 
  228.     ECHO "HAn 8 colour Window Backdrop has been copied to your SYS:Prefs/Patterns*ndirectory. This backdrop can be actived using WBPattern!"
  229.   ENDIF
  230.   ECHO "HAnd it has been activated (WbPattern.prefs file has been altered)."
  231. ELSE
  232.   ECHO "HUse WbPattern to put it on your worbench!"
  233. ENDIF
  234.  
  235. DELETE >NIL: WbPattern#?.prefs
  236. WBPattern FROM SYS:Prefs/Env-Archive/Sys/WbPattern.prefs USE
  237.  
  238. ECHO NOLINE "HPress Return... "
  239. SET >NIL: Return ?
  240. ECHO HBBBBBBBBBBH
  241.  
  242. ;Superb usage of 'list' in order to rename the iconz.
  243. ECHO NOLINE "CNow installing your icons..."
  244. IF $Q1 EQ Y
  245.   LIST #? >RAM:Iconz LFORMAT "DELETE >NIL: *"%P%S*"" ALL SUB .info2
  246. ELSE
  247.   LIST >RAM:Iconz LFORMAT "DELETE >NIL: *"%P%M.info*"*nRENAME >NIL: *"%P%S*" *"%P%M.info*"" ALL SUB .info2
  248. ENDIF
  249. EXECUTE >NIL: RAM:Iconz
  250. DELETE >NIL: RAM:Iconz
  251. ECHO "...FINISHED!!!"
  252.  
  253. ;WOW! a scroll! You saw that?!
  254. ECHO "$scrollDN$scrollDN*ec"
  255.  
  256. ;move outside the Australia-install dir...
  257. CD /
  258. SET Path "$Path"Australia
  259. ECHO "And now... All HELL will break loose! Just a second...*n"
  260. COPY Australia-install $Path ALL
  261.  
  262. ECHO NOLINE "*nCleaning up..."
  263. DELETE >NIL: Australia-install ALL
  264.  
  265. ;create a script in ram to delete this installer...
  266. ECHO >RAM:KillInstaller "WAIT 3*nCD *"`CD`*"*nDELETE Australia-install ALL*nDELETE Australia.#?"
  267. CD $Path
  268.  
  269. ECHO "*ec"
  270. TYPE TP-Logo.ASCII
  271. ECHO "H    That's IT! The Australia EP is yours for EVER! Explore The Outback!"
  272. ECHO NOLINE "HCPress Return"
  273. SET >NIL: Return ?
  274.  
  275. ECHO "$scrollDN$scrollDN"
  276. TYPE TP-Australia.ASCII
  277. ECHO HBBBBBBBBBBH
  278. ECHO "C- This installer was created by the following Problem members-"
  279. ECHO "*nCGraphics*nCSolution*nCAlcoRhythm"
  280. ECHO "*nCCoding/Scripting*nCAlcoRhythm*nCSolution"
  281. ECHO "*nCDesign*nCWanda"
  282. ECHO "*nCQuality Assurance*nCCSilla*nCInfinity"
  283. ECHO "*nCMusic*nCAlcoRhythm"
  284. ECHO NOLINE "C Press Return "
  285. SET >NIL: Return ?
  286.  
  287. ECHO "$scrollDN$scrollDN"
  288. TYPE TP-Australia.ASCII
  289. ECHO HBBBBBBBBBBH
  290. ECHO " The Australia EP project is brought to you by The Problem Collective 1995*nC- It may only be spread in the original unchanged archive -*n"
  291. ECHO "CMusic:CGraphics:*nCAlcoRhythmCMushRoom (Logos)*nCSolutionCAlcoRhythm/Solution (Icons)*n"
  292. ECHO "CCoding:*nCAlcoRhythm (ASCII-Editor, SetRGB)*n*nCThe Problem wishes to thank:*nCPeter Hjelt (Excellent SmartPlay)*nCJohn Hendrikx (FastView)"
  293. ECHO "CHellRaiser (The Twilight Zone)*nCLeo Elsinga (TP Internet)*nCAcid Software (Blitz Basic 2)*nCAnd The People Of Australia (Outback)*n"
  294. ECHO "CWe're The Problem, Gotta Love Us!"
  295. ECHO NOLINE "C Press Return "
  296. SET >NIL: Return ?
  297.  
  298. ECHO "$scrollDN$scrollDN"
  299. ECHO "HCWe're The Problem, Gotta Love Us!H"
  300.  
  301. ;delete the ASCII-logos
  302. DELETE >NIL: TP-#?.ASCII
  303.  
  304. ;move the Australia icon
  305. CD /
  306. RENAME >NIL: Australia/Australia.info Australia.info
  307.  
  308. ;delete this installer...
  309. RUN >NIL: C:EXECUTE RAM:KillInstaller
  310.  
  311. ;but first stop smartplay and endcli...
  312. SP STOP
  313. ENDCLI
  314.  
  315.  
  316.  
  317. ;the SUB_YesNo routine needs the following variables:
  318. ;$Ypos     - the line number string (xH, x is the line number)
  319. ;$YES      - the text to replace a positive answer (y/Y) with
  320. ;$NO       - the text to replace a negative answer (n/N) with
  321.  
  322. LAB SUB_YesNo
  323.   ECHO NOLINE "$Ypos$empty$YposC"
  324.  
  325.   SET answer ""
  326.   SET >NIL: answer ?
  327.  
  328.   IF "$answer" EQ "y"
  329.     SET answer "Y"
  330.   ENDIF
  331.   IF "$answer" EQ "n"
  332.     SET answer "N"
  333.   ENDIF
  334.   IF "$answer" EQ "Y"
  335.     ECHO "$YposC$YES"
  336.   ELSE 
  337.     IF "$answer" EQ "N"
  338.       ECHO "$YposC$NO"
  339.     ELSE
  340.       SKIP BACK SUB_YesNo
  341.     ENDIF
  342.   ENDIF
  343. SKIP BACK $label
  344.  
  345. LAB Pics8col
  346. CD Backdrops/
  347. pictocli >NIL: bugles1 20 68
  348. pictocli >NIL: bugles1 155 68
  349. pictocli >NIL: bugles1 20 153
  350. pictocli >NIL: bugles1 155 153
  351. pictocli >NIL: bugles2 330 68
  352. pictocli >NIL: bugles2 465 68
  353. pictocli >NIL: bugles2 330 153
  354. pictocli >NIL: bugles2 465 153
  355. CD /
  356. SKIP BACK $label
  357.  
  358. LAB Pics4col
  359. CD Backdrops/
  360. pictocli >NIL: bugles3 20 68
  361. pictocli >NIL: bugles3 155 68
  362. pictocli >NIL: bugles3 20 153
  363. pictocli >NIL: bugles3 155 153
  364. pictocli >NIL: bugles4 330 68
  365. pictocli >NIL: bugles4 465 68
  366. pictocli >NIL: bugles4 330 153
  367. pictocli >NIL: bugles4 465 153
  368. CD /
  369. SKIP BACK $label
  370.